﻿using System;

namespace WorkPermit
{
    class Program
    {
        static void Main(string[] args)
        {
            Console.WriteLine("Work Permit");

            int minAge = 16;
            int maxAge = 65;

            Console.WriteLine("How old are you?");
            Console.Write("I'm ");

            int age = int.Parse(Console.ReadLine());

            if(age >= minAge && age < maxAge)
            {
                Console.WriteLine("You are allowed to work.");
            }
            else
            {
                if(age < minAge)
                {
                    Console.WriteLine("Sorry, you are too young.");
                }
                
                if(age >= maxAge)
                {
                    Console.WriteLine("Sorry, you have to retire.");
                }
            }

            Console.ReadKey();
        }
    }
}
